package org.sample.springboot.verifier;

import org.sample.springboot.model.Address;

import java.util.function.Consumer;

import static org.junit.Assert.assertEquals;

public class AddressVerifier extends Verifier<Address> {

	private AddressVerifier() {

	}

	public static interface AddressPropVerifier extends Consumer<Address> {

	}

	public static AddressVerifier expect(AddressPropVerifier... propVerifiers) {
		AddressVerifier verifier = new AddressVerifier();
		verifier.propVerifiers = propVerifiers;
		return verifier;
	}

	public static AddressPropVerifier street(String street) {
		return obj -> assertEquals(street, obj.getStreet());
	}

}
